From: Aaron Schulz Date: Fri, 24 Jul 2009 09:22:51 +0000 (+0000) Subject: Avoid some silly unlink notices X-Git-Tag: 1.31.0-rc.0~40750 X-Git-Url: http://git.cyclocoop.org/%7D%7Cconcat%7B?a=commitdiff_plain;h=6f265ace06d0c5d5c9a871ebcb7afc8fc67404f2;p=lhc%2Fweb%2Fwiklou.git Avoid some silly unlink notices --- diff --git a/includes/Cdb_PHP.php b/includes/Cdb_PHP.php index f2a044c55b..b2229093a6 100644 --- a/includes/Cdb_PHP.php +++ b/includes/Cdb_PHP.php @@ -251,7 +251,7 @@ class CdbWriter_PHP extends CdbWriter { public function close() { $this->finish(); fclose( $this->handle ); - if ( wfIsWindows() ) { + if ( wfIsWindows() && file_exists($this->realFileName) ) { unlink( $this->realFileName ); } if ( !rename( $this->tmpFileName, $this->realFileName ) ) {